﻿<%@ Page Language="C#" AutoEventWireup="true" CodeFile="jq_getJSON.aspx.cs" Inherits="temp_jq_getJSON" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml" >
<head runat="server">
    <title>获得联系人信息</title>
	<script type="text/javascript" src="../jquery/126/jquery-1.2.6.js"></script>	<script language="javascript" type="text/javascript">	    function getlinkman()	    {	        var url='../ajax/GetLinkman.ashx?lmid='+$("#linkmanid").val();	        	        $.getJSON(url,	            function(linkman)	            {	                $("#result").append(linkman['name']);	                $("#result").append(linkman['company']);	                $("#company").val(linkman['company']);	            }	        );	    }	    	</script></head>
<body>
    <form id="form1" runat="server">
    <div>
    联系人ID<asp:TextBox ID="linkmanid" runat="server"></asp:TextBox><input type="button" title="获得" value="获得" onclick="getlinkman()" /><br />
    <div id="result"></div>
    </div><asp:TextBox ID="company" runat="server" Text="eee"></asp:TextBox>
    </form>
</body>
</html>
